#pragma once

typedef void* pint;

// const values
const int MAX_SHADER_COUNT_PER_PROGRAM = 6;

struct VertexDesc
{
	static const size_t COLOR_FLAG = 0x80000000;

	VertexDesc()
	{
		sizeofVertex = sizeof(float)*3;
		positionOffset = 0;
		positionStride = 3;
	}

	size_t sizeofVertex;
	size_t positionOffset;
	size_t positionStride;
	size_t flag;
	size_t texFlag;
	size_t colorOffset;

	bool hasColor() const
	{
		return (flag & COLOR_FLAG) == COLOR_FLAG;
	}
};

// vertex struct for common usage
struct Vertex
{
	//float pos[4];
	//float tex[4];
	//float nor[4];
	//float map[4];
	float pos[3];
	//float color[4];
};

enum ShaderContex
{
	Shader_Vertex,
	Shader_Pixel,
	Shader_Geometry,
	Shader_Compute,
};

// todo read from file
const std::string SHADER_PATH("../assets/shader/");